import matplotlib.pyplot as plt
import numpy as np
plt.rcParams['font.sans-serif'] = ['SimHei']
plt.rcParams['axes.unicode_minus'] = False

x = np.arange(0, 10, 0.1)
y1 = np.sin(x)
y2 = np.cos(x)

plt.figure(figsize=(10, 6))
plt.fill_between(x, y1, alpha=0.5, label='sin(x)', color='skyblue')
plt.fill_between(x, y2, alpha=0.5, label='cos(x)', color='lightgreen')

plt.title('面积图')
plt.legend()
plt.xlabel('x')
plt.ylabel('y')
plt.grid(True,ls=':')
plt.show()